<?php

include('atributosComuns.class.php');

/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 * Description of input
 *
 * @author User
 */
class Input extends AtributosComuns{
    
        private $end = array('accept'=>null,
                                    'label'=>null,
                                    'acceskey'=>null,
                                    'alt'=>null,
                                    'checked'=>null,
                                    'disabled'=>null,
                                    'maxlenght'=>null,
                                    'name'=>null,
                                    'readonly'=>null,
                                    'size'=>null,
                                    'src'=>null,
                                    'tabindex'=>null,
                                    'type'=>null,
                                    'value'=>null);

//        public $atributos = array_merge($this->atrCom,$this->end);
        
    

	public function show(){
	
            $html = '';
            
            if($this->atributos['label']){
                $html .= '<label for="'.$this->atributos['id'].'">'.$this->atributos['label'].'</label>';
            }
            
            $html .= '<input';

            foreach($this->atributos as $chave => $valor){
                if($valor){
                    $html .= ' '.$chave.'="'.$valor.'"';
                }
            }

            $html .= '"/>';
            
            return $html;
	
	}

	
}

?>
